﻿using Microsoft.Extensions.Configuration;
using System;
using System.Collections.Generic;
using System.IO;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace HBase {
    public class ConfUtil {

        static IConfiguration configuration = new ConfigurationBuilder().SetBasePath(Directory.GetCurrentDirectory()).AddXmlFile("Conf/DataBase.config").Build();
       public static string getStr( string key) {
            return configuration[key + ":connectionString"];
        }
        public static string getMongodb() {
            return getStr( "MongoDB");

        }

        public static string getDbName() {
            return getStr( "dbName");

        }
    }
}
